import Vue from 'vue'
import App from './App.vue'
import router from './router'
import store from './store'
import Element from 'element-ui'
import 'element-ui/lib/theme-chalk/index.css';
import VueClipboard from 'vue-clipboard2'
// import WHFlow from '@/components/whFlow'
// import WHFlow from 'wh-flow'
// import 'wh-flow/lib/wh-flow.css';
// Vue.use(WHFlow)

// import FormMaking from '@/components/whForm/lib/vue-form-making'
// import '@/components/whForm/lib/vue-form-making/dist/FormMaking.css'

// Vue.use(FormMaking)


import VueI18n from 'vue-i18n'
Vue.use(VueI18n)

import enLocale from 'element-ui/lib/locale/lang/en'
import zhLocale from 'element-ui/lib/locale/lang/zh-CN'
import enUS from '@/components/whForm/lang/en-US'
import zhCN from '@/components/whForm/lang/zh-CN'

// 创建i18n实例
const i18n = new VueI18n({
  locale: 'zh-CN', // 设置默认语言
  messages: {
    'en-US': {
      ...enLocale,
      ...enUS
    },
    'zh-CN': {
      ...zhLocale,
      ...zhCN
    }
  }
});

Vue.use(VueClipboard)
Vue.use(Element, {
  size: 'small',
  i18n: (key, value) => i18n.t(key, value)
})
Vue.config.productionTip = false

new Vue({
  i18n,
  router,
  store,
  render: h => h(App)
}).$mount('#app')
